package org.example.juc.p07;

/**
 * @author lou ke
 * @since 2024/2/10 13:56
 */
public class CreateThreadDemo {
    public static void main(String[] args) {

        // 继承Thread
        MyThread myThread = new MyThread();
        myThread.start(); // 开启异步线程

        // 实现Runnable接口
        Thread thread = new Thread(new MyRunnable());
        thread.start();

        System.out.println("主线程");
    }
}
